/*
 * WebController.h
 *
 *  Created on: Jun 16, 2011
 *      Author: ToanNhan
 */

#ifndef WEBCONTROLLER_H_
#define WEBCONTROLLER_H_

#include "FBase.h"
#include "FWeb.h"
#include "WebForm.h"
#include "../Utility/MyUtil.h"
using namespace Osp::Base;
using namespace Osp::Web::Controls;


class WebController {
private:
	static Web *pWeb;
public:
	static void SetWebControl(Web *pWeb);
	WebController();
	virtual ~WebController();

	static void FindLocation(String &address);
	static void FindLocation(Web *&pWeb, String &address);

	static void FindLocation(String &address, String &icon);
	static void FindLocation(Web *&pWeb, String &address, String &icon);

	static void SetMarkerN(float &latitude, float longitude, String title, bool center);
	static void SetMarkerN(Web *&pWeb, float &latitude, float longitude, String title, bool center);

	static void SetMarkerN(float &latitude, float longitude, String title, String icon, bool center);
	static void SetMarkerN(Web *&pWeb, float &latitude, float longitude, String title, String icon, bool center);

	static void SetMapTypeIdN(int MapTypeId);
	static void SetMapTypeIdN(Web *&pWeb, int MapTypeId);

	static void SetDirection(String &url);
	static void SetDirection(Web *&pWeb, String &url);

	static void SetMyLocationN(float &latitude, float &longitude,bool isCenter);
	static void SetMyLocationN(Web *&pWeb, float &latitude, float &longitude, bool isCenter);
	//setMarkerGoogleBuzz(m_lat, m_lng, m_name, m_icon,  m_placeName, m_address, m_title )
	static void SetGoogleBuzzMarker(float &lat, float &lng, String name, String icon, String placeName, String address,
			String title);
	static void SetGoogleBuzzMarker(Web *&pWeb, float &lat, float &lng, String name, String icon, String placeName,
			String address,	String title);

	static void RemoveAllMultiPointDirectionListStringItem(Web *&pWeb);
	static void RemoveAllMultiPointDirectionListStringItem();

	static void AddListStringItem(Web *&pWeb, String address);
	static void AddListStringItem(String address);

	static void DrawMultiPointDirection(Web *&pWeb);
	static void DrawMultiPointDirection();
};

#endif /* WEBCONTROLLER_H_ */
